package com.example.yls.demoa;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;

/**
 * Created by yls on 2018/11/12.
 */

public class MiddlePriorityReceiver extends BroadcastReceiver{
    @Override
    public void onReceive(Context context, Intent intent) {
        Bundle bundle = getResultExtras(false);
        String name = bundle.getString("NAME");
        int age = bundle.getInt("AGE");
        Log.e("MiddlePriorityReceiver","onReceiver name = " + name + " age = "+ age);
        bundle.putString("ADDRESS","San Francisco");
        bundle.putInt("number",2);
        setResultExtras(bundle);
    }
}
